$(document).ready(function() {
	setInterval(function() {
		var mainLeft = $(".main_left_div");
		var mainRight = $(".main_right_div");
		var nowH = get_scrollTop_of_body() + 400;
		if (nowH > mainRight.height() && nowH < mainLeft.height()) {
			mainRight.css("position", "fixed");
			mainRight.css("margin-left", "650px");
			mainRight.css("margin-top", -mainRight.height() + 400);
		} else if (nowH > mainRight.height()) {
			mainRight.css("position", "fixed");
			mainRight.css("margin-left", "650px");
			mainRight.css("margin-top", -mainRight.height() + 200);
		} else {
			mainRight.css("position", "inherit");
			mainRight.css("margin-left", "0px");
			mainRight.css("margin-top", "0px");
		}
	}, 100);
});